<?php
class ModelDesignBanner extends Model {	
	public function getBanner($banner_id) {
		$query = $this->db->query("SELECT * FROM " . DB_PREFIX . "banner_image bi LEFT JOIN " . DB_PREFIX . "banner_image_description bid ON (bi.banner_image_id  = bid.banner_image_id) WHERE bi.banner_id = '" . (int)$banner_id . "'");
		
		return $query->rows;
	}
    
    public function getBanners()
    {
        $query = $this->db->query("SELECT * FROM " . DB_PREFIX . "banner  WHERE status = 1 ");
        return $query->rows;
    }
}
?>